//package com.lagou.consumer;
//
//import com.lagou.service.IOrderService;
//import lombok.extern.slf4j.Slf4j;
//import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
//import org.apache.rocketmq.spring.core.RocketMQListener;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.stereotype.Component;
//
//@Component
//@Slf4j
//@RocketMQMessageListener(topic = "tp_demo_seckill", consumerGroup = "lg-consumer-grp")
//public class DemoConsumer implements RocketMQListener<String> {
//
//    @Autowired
//    private IOrderService orderService;
//
//    @Override
//    public void onMessage(String msg) {
//        log.info("[onMessage][线程编号:{} 消息内容:{}]", Thread.currentThread().getId(), msg);
//        orderService.update(Integer.valueOf(msg));
//    }
//}
